package com.lzc.springcloud.user.application.representation;

import com.lzc.springcloud.user.domain.identity.SysUserEntity;

public class UserRegisterRepresentation {

    private String username;

    private String password;

    private String confirmPassword;

    private String name;

    private String email;

    private String mobile;

    public String username() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    public String password() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public String confirmPassword() {
        return confirmPassword;
    }

    public void setConfirmPassword(String confirmPassword) {
        this.confirmPassword = confirmPassword;
    }

    public String name() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String email() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email;
    }

    public String mobile() {
        return mobile;
    }

    public void setMobile(String mobile) {
        this.mobile = mobile;
    }

    public SysUserEntity toUser() {
        SysUserEntity userEntity = new SysUserEntity(
            this.username(),
            this.name(),
            this.password(),
            this.email(),
            this.mobile()
        );
        return userEntity;
    }
}
